/*
 * vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4 foldmethod=marker:
 *
 * follow.h
 *
 * C.C.Allison
 * chris.allison@hotmail.com
 *
 * Started: Friday 28 December 2012, 22:30:48
 * Version: 0.00
 * Revision: $Id: follow.h 53 2013-02-18 22:43:38Z chris.charles.allison@gmail.com $
 * Last Modified: Sunday 17 February 2013, 11:45:10
 */

#include "defs.h"
#include "macros.h"
#include "tools.h"
#include "configfile.h"
#include "regex.h"
#include "structs.h"
#include "globals.h"

extern int emitdata(struct SummaryLine *sl);
extern struct LogFile *rotatedlogs;
/* extern struct ConfigItem *configuration; */

struct SummaryLine *createNewSummaryLine( long summarysize );
void freeSummaryLine( struct SummaryLine *sl );
time_t is_logline(char *line, char *format);
void resetFollowFile(struct FollowedFile *ffile);
struct FollowedFile *setupfollowfile(long fpos);
/* struct FollowedFile *setupfollowfile(char *filename, char *searchfor, char *dateformat, long bufsize, int summarysize, long fpos, int sleeptime, int summarize); */
void *freeffile(struct FollowedFile *ffile);
int followfile(struct FollowedFile *ffile);
int readThroughFFile(struct FollowedFile *ffile, FILE *ffp);
int nextLine(struct FollowedFile *ffile, FILE *ffp);
struct SummaryLine *checkLine(struct FollowedFile *ffile);
